--lua script
--#include "data\envir\FuBen.txt" once
--#include "data\functions\Common\CommonBoss.lua" once				--BOSS通用功能
--#include "data\functions\Common\CommomQuest.lua" once				--任务通用功能
--#include "data\functions\Boss\PersonBossCommon.lua"  once  		--个人BOSS
--#include "data\functions\Boss\StoneTombPigCommon.lua"  once  		--石墓烧猪
----#include "data\functions\Boss\WildBossCommon.lua"  once  		--野外BOSS
--#include "data\functions\Boss\MayaPalaceCommon.lua"  once  		--玛雅神殿
--#include "data\functions\Boss\LockBossCommon.lua"  once  		    --锁妖塔
--#include "data\functions\Boss\BossHomeCommon.lua"  once  		    --BOSS之家
--#include "data\functions\Boss\HuntBossTreasure.lua" once 			--神兵宝阁
--#include "data\functions\Boss\BossAttackCommon.lua"  once  		--BOSS来袭
--#include "data\functions\Guild\GuildBoss.lua"  once  		        --行会BOSS
--#include "data\functions\Guild\GuildGuard.lua"  once  		    --守卫行会
--#include "data\functions\Guild\GuildAdventure.lua"  once  		--行会宝藏探险
--#include "data\functions\Guild\GuildOwnScene.lua"  once  		    --行会冠名地图

--#include "data\functions\welfare\OfflineExpCopy.lua"  once  		--离线副本
--#include "data\functions\fuben\SbkFuben.lua"  once    		    --SBK体验副本

--#include "data\functions\boss\GodShieldBossCommon.lua" once 		--神盾副本boss
--#include "data\functions\Boss\DreamLandBossCommon.lua" once 		--幻境boss
--#include "data\functions\Fuben\MagicCity.lua"  once  		        --魔域迷城
--#include "data\functions\Fuben\SpaceTrial.lua"  once  		 	--血域试炼
--#include "data\functions\Boss\EquipBossCommon.lua" once 			--装备boss
--#include "data\functions\Boss\BossBattleField.lua" once 			--BOSS战场
--#include "data\functions\Fuben\TeamFuben.lua" once 			    --团队副本
--#include "data\functions\Boss\ArenaBoss.lua" once 			    --擂台BOSS
--#include "data\functions\Exep\ExepArenaBoss.lua" once 			--擂台BOSS（体验）
--#include "data\functions\Boss\BloodFight.lua" once 			    --血战到底
--#include "data\functions\Fuben\KongFuMaster.lua"  once  		    --练功师
--#include "data\functions\Fuben\SkyTower.lua"  once  		        --通天塔
--#include "data\functions\Vip\VipCommon.lua"  once  		        --VIPBOSS
--#include "data\functions\Vip\ConcVipBoss.lua" once 				--月卡boss
--#include "data\functions\Activity\DailyActivity\SceneAnswer.lua"  once --活动答题

--#include "data\functions\Activity\DailyActivity\MulphaAdventure.lua" once					--玛法大冒险

--#include "data\functions\Exep\ExepMoZun.lua" once                 --魔尊战场（体验）

--#include "data\functions\Activity\DailyActivity\BaoZangActivity.lua" once					--宝藏传说
--#include "data\functions\Activity\DailyActivity\DarkBox.lua"  once 	--暗之宝箱
--#include "data\functions\Boss\TempleWoMa.lua"  once               --神殿沃玛

--#include "data\functions\Activity\DailyActivity\SupplyContention.lua" once				--补给争夺
--#include "data\functions\Activity\DailyActivity\TwelvePalaces.lua" once                   --十二星宮
--#include "data\functions\Boss\WorldBossCommon.lua"  once               --世界BOSS
--#include "data\functions\Activity\Carnival\CarnivalCommon.lua" once 	--狂欢boss
--------------以下是跨服功能--------------------------
--#include "data\functions\Cross\CrossBossAttack.lua"  once  		--跨服BOSS来袭

--#include "data\functions\Cross\CrossGatherCrystal.lua" once		--跨服水晶


---------------------------玛雅神殿(放在MobBossCommonConfig前)----------begin------------------------------------------------
--注册mob事件
for palaceIdx, palaceCfg in ipairs( MayaPalaceConfig ) do
	for bossIdx, bossId in ipairs( palaceCfg.boss ) do
		--print("MonMobDispatcher.MayaPalaceBossMob, bossId="..bossId)
		MonMobDispatcher.register( bossId, OnMayaPalaceBossMob)
	end
end


--注册怪物 death事件
for palaceIdx, palaceCfg in ipairs( MayaPalaceConfig ) do
	for bossIdx, bossId in ipairs( palaceCfg.boss ) do
		--print("MonDieDispatcher.MayaPalaceBossDie, bossId="..bossId)
		--MonDieDispatcher.register( bossId, OnMayaPalaceBossDie )
		MonDeathDispatcher.register( bossId, OnMayaPalaceBossDeath )	
	end
end
---------------------------玛雅神殿(放在MobBossCommonConfig前)----------end--------------------------------------------------


---------------------------Boss之家(放在MobBossCommonConfig前)----------begin------------------------------------------------
--注册mob事件
for i, v in ipairs( BossHomeConfig ) do
	for bossIdx, bossId in ipairs( v.boss ) do
		MonMobDispatcher.register( bossId, OnBossHomeBossMob)
	end
end


--注册怪物 death事件
for i, v in ipairs( BossHomeConfig ) do
	for bossIdx, bossId in ipairs( v.boss ) do
		MonDeathDispatcher.register( bossId, OnBossHomeBossDeath )	
	end
end
---------------------------Boss之家(放在MobBossCommonConfig前)----------end--------------------------------------------------



---------------------------神兵宝阁(放在MobBossCommonConfig前)----------begin------------------------------------------------

--注册mob事件
for i, v in ipairs( HuntBossTreasureCfg ) do
	for bossIdx, bossId in ipairs( v.boss ) do
		MonMobDispatcher.register( bossId, OnHuntBossTreasureBossMob)
	end
end


--注册怪物 death事件
for i, v in ipairs( HuntBossTreasureCfg ) do
	for bossIdx, bossId in ipairs( v.boss ) do
		MonDeathDispatcher.register( bossId, OnHuntBossTreasureBossDeath )	
	end
end

---------------------------神兵宝阁(放在MobBossCommonConfig前)----------end--------------------------------------------------

----------------------------副本任务怪---------begin------------------------------------------------
for i, fubenCfg in ipairs( FuBen ) do
	if fubenCfg.questMonsters then
		for bossIdx, oneMon in ipairs( fubenCfg.questMonsters ) do
			--print("--->MonDieDispatcher, monId="..oneMon.monsterId)
			MonDieDispatcher.register( oneMon.monsterId, OnCommonQuestFubenMonsterKilled )
		end
	end
end
----------------------------副本任务怪---------begin------------------------------------------------


----------------------------通用BOSS---------begin--------key->value----------------------------------------
for bossId, bossCfg in pairs( BossScoreConfig ) do
	--print("MonDieDispatcher, bossId="..bossId)
	MonDieDispatcher.register(bossId, OnCommonBossDie)
end


--注册mob事件
for bossId, bossCfg in pairs( MobBossCommonConfig ) do
	if bossCfg.mobMsg then			--部分BOSS需要注册mob事件
		--print("OnCommonBossMob, bossId="..bossId)
		MonMobDispatcher.register(bossId, OnCommonBossMob)
	end
end

--注册die事件
for bossId, bossCfg in pairs( MobBossCommonConfig ) do
	--print("OnCommonBossDie, bossId="..bossId)
	MonDieDispatcher.register(bossId, OnCommonBossDie)				--需要killer的用 MonDieDispatcher
	MonDeathDispatcher.register(bossId, OnCommonBossDeath)			--不需要killer的用 MonDeathDispatcher
	if bossCfg.deadMonsterId and bossCfg.deadMonsterId > 0 then
		--print("OnCommonBossTimeOut, deadMonsterId="..bossCfg.deadMonsterId)
		MonLiveTimeOutDispatcher.register( bossCfg.deadMonsterId, OnCommonBossDeadMonsterTimeout)	--注册timeout事件
	end
end
---------------------------通用BOSS----------end--------------------------------------------------


----------------------------行会宝藏探险---------begin------------------------------------------------
for idx, advCfg in ipairs( GuildConfig.guildAdventure.adventures ) do
	for monIdx, oneMon in ipairs( advCfg.monsters ) do
		--print("----->MonDieDispatcher, monId="..oneMon.monsterId)
		MonDieDispatcher.register(oneMon.monsterId, OnGuilAdventureMonDie)
	end
end
---------------------------行会宝藏探险----------end--------------------------------------------------

----------------------------行会BOSS---------begin------------------------------------------------
for idx, bossCfg in ipairs( GuildConfig.guildBoss ) do
	for monIdx, oneMon in ipairs( bossCfg.monsters ) do
		--print("----->MonDieDispatcher, monId="..oneMon.monsterId)
		MonMobDispatcher.register(oneMon.monsterId, OnGuildBossMob)
		MonDieDispatcher.register(oneMon.monsterId, OnGuildBossDie)
		MonLiveTimeOutDispatcher.register( oneMon.monsterId, OnGuildBossTimeout )
	end
end
---------------------------行会BOSS----------end--------------------------------------------------


----------------------------守卫行会---------begin------------------------------------------------
for idx, bossCfg in ipairs( GuildConfig.guildGuard ) do
	MonDieDispatcher.register( bossCfg.guard.monsterId, OnGuildGuardGuardDie )
	for freshIdx, oneFresh in ipairs( bossCfg.monsters ) do
		for monIdx, oneMon in ipairs( oneFresh ) do
			MonDieDispatcher.register( oneMon.monsterId, OnGuildGuardMonsterDie )
		end
	end
end
---------------------------守卫行会----------end--------------------------------------------------


----------------------------个人BOSS---------begin------------------------------------------------
for idx, bossConfig in ipairs( PersonBossConfig ) do
	for bossIdx, oneMon in ipairs( bossConfig.monsters ) do
		--print("MonDieDispatcher, monId="..oneMon.monsterId)
		MonDieDispatcher.register(oneMon.monsterId, OnPersonBossDie)
	end
end
---------------------------个人BOSS----------end--------------------------------------------------

----------------------------迷幻魔宫---------begin------------------------------------------------
for idx, cityCfg in ipairs( MagicCityCfg.cities ) do
	for bossIdx, oneMon in ipairs( cityCfg.monsters or {} ) do
		--print("--->1 MonDieDispatcher, monId="..oneMon.monsterId)
		MonDieDispatcher.register( oneMon.monsterId, OnMagicCityMonsterDie )
		for subMonIdx, subOneMon in pairs( oneMon.mobMonsWenDie or {} ) do
			MonDieDispatcher.register( subOneMon.monsterId, OnMagicCitySubMonsterDie )
		end
	end

	for bossIdx, oneBoss in ipairs( cityCfg.boss or {} ) do
		--print("--->1 MonDieDispatcher, monId="..oneMon.monsterId)
		MonDieDispatcher.register( oneBoss.monsterId, OnMagicCityMonsterDie )
	end
end

for idx, cityCfg in ipairs( MagicCityCfg.cities ) do
	if cityCfg.baby then
		MonDieDispatcher.register( cityCfg.baby.monsterId, OnMagicCityBabyDie )
	end
end

---------------------------迷幻魔宫----------end--------------------------------------------------

---------------------------血域试炼---------begin------------------------------------------------
for bossIdx, bossCfg in ipairs( SpaceTrialCfg.boss ) do
	MonMobDispatcher.register( bossCfg.monsterId, OnSpaceTrialBossMob )
	MonDieDispatcher.register( bossCfg.monsterId, OnSpaceTrialBossDie )
end

---------------------------血域试炼----------end--------------------------------------------------


---------------------------BOSS战场---------begin------------------------------------------------
for freshidx, freshCfg in ipairs( BossBattleFieldCfg.freshBoss ) do
	for bossIdx, bossCfg in ipairs( freshCfg.boss ) do
		--print("------------->>MonDieDispatcher, monId="..bossCfg.monsterId)
		MonDieDispatcher.register( bossCfg.monsterId, OnBossBattleFieldBossDie )
	end
end
---------------------------BOSS战场----------end--------------------------------------------------


----------------------------BOSS来袭---------begin------------------------------------------------
for freshIdx, freshConfig in ipairs( BossAttackConfig ) do
	for batchIdx, oneBatch in ipairs( freshConfig.freshMonsters ) do
		for monIdx, oneMon in ipairs( oneBatch ) do
			--print("------------->>MonDieDispatcher, monId="..oneMon.monsterId)
			MonDieDispatcher.register(oneMon.monsterId, AttackBossOnMonsterDie)
		end
	end
end
---------------------------BOSS来袭----------end--------------------------------------------------

----------------------------石墓烧猪---------begin------------------------------------------------
for freshIdx, freshMons in ipairs( StoneTombPigConfig.freshMon ) do
	for monIdx, monsterId in ipairs( freshMons ) do
		MonDieDispatcher.register( monsterId, OnStoneTombPigMonsterDie )
	end
end

for freshIdx, freshMons in ipairs( StoneTombPigConfig.freshMon ) do
	--print("MonLiveTimeOutDispatcher, monId="..oneMon.monsterId)
	for monIdx, monsterId in ipairs( freshMons ) do
		MonLiveTimeOutDispatcher.register( monsterId, OnStoneTombPigMonsterTimeout )
	end
end


for freshIdx, freshMons in ipairs( StoneTombPigConfigForExp.freshMon ) do
	for monIdx, monsterId in ipairs( freshMons ) do
		MonDieDispatcher.register( monsterId, OnStoneTombPigMonsterDie )
	end
end

for freshIdx, freshMons in ipairs( StoneTombPigConfigForExp.freshMon ) do
	--print("MonLiveTimeOutDispatcher, monId="..oneMon.monsterId)
	for monIdx, monsterId in ipairs( freshMons ) do
		MonLiveTimeOutDispatcher.register( monsterId, OnStoneTombPigMonsterTimeout )
	end
end

---------------------------石墓烧猪----------end--------------------------------------------------

---------------------------野外BOSS----------begin------------------------------------------------
--[[
for bossIdx, oneBoss in ipairs(WildBossConfig) do
	--print("MonLiveTimeOutDispatcher, bossId="..oneBoss.monsterId)
	MonLiveTimeOutDispatcher.register(oneBoss.monsterId, OnWildBossMob)
end


for bossIdx, oneBoss in ipairs(WildBossConfig) do
	--print("MonDieDispatcher, monId="..oneBoss.monsterId)
	MonDieDispatcher.register(oneBoss.monsterId, OnWildBossDie)
end
]]
---------------------------野外BOSS----------end--------------------------------------------------


---------------------------锁妖塔----------begin------------------------------------------------
--[[
for level, lockBossCfg in ipairs(LockBossConfig) do
	--print("MonDieDispatcher, monId="..lockBossCfg.monsterId)
	MonDieDispatcher.register(lockBossCfg.monsterId, OnLockBossDie)
end

for level, lockBossCfg in ipairs(LockBossConfig) do
	--print("MonLiveTimeOutDispatcher, deadmonId="..lockBossCfg.deadMonsterId)
	MonLiveTimeOutDispatcher.register(lockBossCfg.deadMonsterId, OnDeadLockBossLiveTimeOut)
end
]]
---------------------------锁妖塔----------end--------------------------------------------------


---------------------------离线副本----------begin------------------------------------------------

for i, offLineExpScene in ipairs(OfflineExpCopyCfg.OfflineExpScenes) do
	for j, conds in ipairs(offLineExpScene.GetCond) do
		for idx, cond in ipairs(conds) do
			if cond.event == OfflineExpSceneGetEvent.offlineKillMonster then
				MonDieDispatcher.register(cond.param, OfflineExpMonsterDie)
			end
		end
	end
end

---------------------------离线副本----------end--------------------------------------------------

----------------------------SBK副本--------begin------------------------------------------------
for fubenIdx, fubenConfig in ipairs( SbkFubenConfig ) do
	for monIdx, oneMon in ipairs( fubenConfig.monsters ) do
		if not oneMon.isFriend then
			--print("------------->>MonDieDispatcher, monId="..oneMon.monsterId)
			MonDieDispatcher.register(oneMon.monsterId, OnSbkFubenMonsterDie)
		end
	end
end
---------------------------SBK副本----------end--------------------------------------------------


----------------------------幻境boss--------begin------------------------------------------------
for idx, BossLst in ipairs( DreamLandBossConfig.BossList ) do
	for ii, oneMon in ipairs( BossLst ) do
		if oneMon then
			MonDieDispatcher.register(oneMon.monsterId, OnDreamLandBossMonDie)
		end
	end
end
---------------------------幻境boss----------end--------------------------------------------------

----------------------------装备boss--------begin------------------------------------------------
for idx, BossLst in ipairs( EquipBossCfg.BossList ) do
	for ii, oneMon in ipairs( BossLst.monsters ) do
		for iii, curMon in ipairs( oneMon.monster ) do
			if curMon and curMon.boss then
				MonDieDispatcher.register(curMon.boss.monsterId, OnEquipBossMonsterDie)
			end
		end
	end
end
---------------------------装备boss----------end--------------------------------------------------

----------------------------团队副本--------begin------------------------------------------------
for fubenIdx, fubenCfg in ipairs( TeamFubenConfig ) do
	for monIdx, oneMon in ipairs( fubenCfg.monsters ) do
		--print("------------->>MonDieDispatcher, monId="..oneMon.monsterId)
		MonDieDispatcher.register(oneMon.monsterId, OnTeamFubenMonsterDie)
	end
end
---------------------------团队副本----------end--------------------------------------------------

----------------------------擂台BOSS--------begin------------------------------------------------
for bossIdx, bossCfg in ipairs( ArenaBossConfig.boss ) do
	--print("------------->>MonDieDispatcher, bossId="..bossCfg.boss.monsterId)
	MonDieDispatcher.register( bossCfg.boss.monsterId, OnArenaBossDie )
end

for bossIdx, bossCfg in ipairs( ExepArenaBossConfig.boss ) do
	--print("------------->>MonDieDispatcher, bossId="..bossCfg.boss.monsterId)
	MonDieDispatcher.register( bossCfg.boss.monsterId, OnExepArenaBossDie )
end
---------------------------擂台BOSS----------end--------------------------------------------------

----------------------------活动答题---------begin------------------------------------------------
--print("---------->>MonDieDispatcher, bossId="..SceneAnswerConfig.monsters[1].monsterId)
MonDieDispatcher.register( SceneAnswerConfig.monsters[1].monsterId, OnSceneAnswerMonsterDie )
----------------------------活动答题----------end--------------------------------------------------

----------------------------血战到底--------begin------------------------------------------------
for bossIdx, bossCfg in ipairs( BloodFightCfg.boss ) do
	MonDieDispatcher.register( bossCfg.bossId, OnBloodFightBossDie )
end
---------------------------血战到底----------end--------------------------------------------------

----------------------------练功师--------begin------------------------------------------------
for masterIdx, masterCfg in ipairs( KongFuMasterConfig ) do
	for monIdx, oneMon in ipairs( masterCfg.monsters ) do
		--print("------------->>MonDieDispatcher, monId="..oneMon.monsterId)
		MonDieDispatcher.register(oneMon.monsterId, OnKongFuMasterDie)
	end
end
---------------------------练功师----------end--------------------------------------------------

----------------------------VIP BOSS-------begin------------------------------------------------
for vipGradeIdx, vipGradeCfg in ipairs( VipConfig.VipGrade ) do
	if vipGradeCfg.boss then
		--print("------------->>MonDieDispatcher, vipBossId="..vipGradeCfg.boss.monsters[1].monsterId)
		MonDieDispatcher.register( vipGradeCfg.boss.monsters[1].monsterId, OnVipBossDie )
	end
end
---------------------------VIP BOSS---------end--------------------------------------------------

----------------------------月卡boss-------begin------------------------------------------------
for i, v in ipairs( VipConcCfg.Vips ) do
	if v.boss then
		MonDieDispatcher.register( v.boss.monsters[1].monsterId, OnConcVipBossDie )
	end
end
---------------------------月卡boss---------end--------------------------------------------------

----------------------------通天塔-------begin------------------------------------------------
for floorIdx, floorCfg in ipairs( SkyTowerCfg.floors ) do
	for monIdx, oneMon in ipairs( floorCfg.monsters ) do
		--print("------------->>MonDieDispatcher, monId="..oneMon.monsterId)
		MonDieDispatcher.register(oneMon.monsterId, OnSkyTowerBossDie)
	end
end
---------------------------通天塔---------end--------------------------------------------------


---------------------------玛法大冒险---------begin------------------------------------------------
for freshIdx, freshConfig in ipairs( MulphaAdventureConfig.normalRound ) do
	if freshConfig.eventType == MulphaAdventureEvent.fight or
		freshConfig.eventType == MulphaAdventureEvent.canNotPassFight then
		if freshConfig.boss and #freshConfig.boss > 0 then
			for monsterIdx, monsterConfig in ipairs( freshConfig.boss ) do
				MonDieDispatcher.register(monsterConfig.monsterId, OnMulphaAdventureMonsterDie)
			end
		end
		if freshConfig.monsters and #freshConfig.monsters > 0 then
			for monsterIdx, monsterConfig in ipairs( freshConfig.monsters ) do
				MonDieDispatcher.register(monsterConfig.monsterId, OnMulphaAdventureMonsterDie)
			end
		end
	end
end

for freshIdx, freshConfig in ipairs( MulphaAdventureConfig.specialRound ) do
	if freshConfig.eventType == MulphaAdventureEvent.fight or
		freshConfig.eventType == MulphaAdventureEvent.canNotPassFight then
		if freshConfig.boss and #freshConfig.boss > 0 then
			for monsterIdx, monsterConfig in ipairs( freshConfig.boss ) do
				MonDieDispatcher.register(monsterConfig.monsterId, OnMulphaAdventureMonsterDie)
			end
		end
		if freshConfig.monsters and #freshConfig.monsters > 0 then
			for monsterIdx, monsterConfig in ipairs( freshConfig.monsters ) do
				MonDieDispatcher.register(monsterConfig.monsterId, OnMulphaAdventureMonsterDie)
			end
		end
	end
end
---------------------------玛法大冒险----------end-------------------------------------------------

----------------------------盟重杀神（体验）---------begin------------------------------------------------
for bossIdx, bossCfg in ipairs( ExepMoZunConfig.monsters ) do
	MonDieDispatcher.register( bossCfg.monsterId, OnExepMoZunBossDie )
end

---------------------------盟重杀神（体验）--------end--------------------------------------------------

----------------------------行会冠名地图---------begin------------------------------------------------
for bossId, ownSceneCfg in pairs( GuildOwnSceneCfg ) do
	MonDieDispatcher.register( bossId, OnGuildOwnSceneBossDie )
end
---------------------------行会冠名地图-----------end--------------------------------------------------


----------------------------神殿沃玛---------begin------------------------------------------------
for bossIdx, bossCfg in ipairs( TempleWoMaConfig.smallBossS) do
	MonMobDispatcher.register( bossCfg.monsterId, OnTempleWoMaSmallBosssMob )
	MonDieDispatcher.register( bossCfg.monsterId, OnTempleWoMaSmallBosssDie )
end
for bossIdx, bossCfg in ipairs( TempleWoMaConfig.bigBossS) do
	MonMobDispatcher.register( bossCfg.monsterId, OnTempleWoMaBigBosssMob )
	MonDieDispatcher.register( bossCfg.monsterId, OnTempleWoMaBigBosssDie )
end

---------------------------神殿沃玛--------end--------------------------------------------------


----------------------------跨服BOSS来袭---------begin------------------------------------------------
for freshIdx, freshConfig in ipairs( CrossBossAttackConfig ) do
	for batchIdx, oneBatch in ipairs( freshConfig.freshMonsters ) do
		for monIdx, oneMon in ipairs( oneBatch ) do
			--print("------------->>MonDieDispatcher, monId="..oneMon.monsterId)
			MonDieDispatcher.register(oneMon.monsterId, CrossAttackBossOnMonsterDie)
		end
	end
end
---------------------------跨服BOSS来袭----------end--------------------------------------------------

----------------------------跨服水晶---------begin------------------------------------------------
for freshIdx, monsterId in ipairs( CrossGatherCrystalCfg.RandomMonsterId ) do
	MonDieDispatcher.register(monsterId, CrossGatherCrystalMonDie)
end
---------------------------跨服水晶----------end--------------------------------------------------

----------------------------宝藏传说---------begin------------------------------------------------
for monIdx, monId in ipairs( BaoZangConfig.monsterIds ) do
	--print("------------->>MonDieDispatcher, monId="..oneMon.monsterId)
	MonDeathDispatcher.register(monId, BaoZangMonDie)
end
---------------------------宝藏传说----------end--------------------------------------------------

----------------------------暗之宝箱---------begin------------------------------------------------
for i,v in ipairs( DarkBoxConfig.Monsters ) do
	for i2, oneMon in ipairs(v.Monster) do
		if oneMon and not oneMon.range then
			MonDieDispatcher.register(oneMon.monsterId, OnDarkBoxMonDie)
		end
	end
end
----------------------------暗之宝箱---------end------------------------------------------------

----------------------------补给争夺---------begin------------------------------------------------
MonDieDispatcher.register(SupplyContentionConfig.boss.monsterId, SupplyContentionMonDie)
---------------------------补给争夺----------end--------------------------------------------------

-----------------------世界BOSS-------begin----------------------
for i,monId in ipairs(WorldBossCfg.bossId) do
	MonMobDispatcher.register( monId, OnWorldBossBosssMob )
	MonDieDispatcher.register( monId, OnWorldBossBosssDie )
end
-----------------------世界BOSS-------end----------------------


---------------------------英雄神盾副本----------begin------------------------------------------------
--注册mob事件
for i, v in ipairs( GodShieldBossConfig.bossList ) do
	for monIdx, monCfg in ipairs( v.monsters ) do
		MonMobDispatcher.register( monCfg.monsterId, OnGodShieldBossMob)
	end
end


--注册怪物 death事件
for i, v in ipairs( GodShieldBossConfig.bossList ) do
	for monIdx, monCfg in ipairs( v.monsters ) do
		MonDieDispatcher.register( monCfg.monsterId, OnGodShieldBossDie )	
	end
end
---------------------------英雄神盾副本----------end--------------------------------------------------
---------------------------狂欢----------begin------------------------------------------------

--注册怪物 death事件
for i,v in ipairs(CarnivalConfig.Boss.monsters) do
	MonDieDispatcher.register(v.monsterId, OnCarnivalBossDie )	
end

---------------------------狂欢----------end------------------------------------------------